package cn.bandeqing.app.entity;

import cn.bandeqing.frame.mybatis.config.InsertOrUpdateListener;
import cn.bandeqing.frame.mybatis.entity.BaseEntity;
import cn.bandeqing.sys.req.AppSaveOrUpdateReq;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.KeyType;
import com.mybatisflex.annotation.Table;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.SuperBuilder;

/**
 * app 实体类。
 *
 * @author fugui
 * @since 2024-03-14
 */
@EqualsAndHashCode(callSuper = true)
@Data
@SuperBuilder
@NoArgsConstructor
@AllArgsConstructor
@Table(value = "bdq_app", onInsert = InsertOrUpdateListener.class, onUpdate = InsertOrUpdateListener.class)
@AutoMapper(target = AppSaveOrUpdateReq.class, convertGenerate = false)
public class App extends BaseEntity {

    @Id(keyType = KeyType.Auto)
    private Long appId;

    private String appPackageId;

    /**
     * 0 = Android  1 = ios
     */
    private Integer appType;

    private String appName;

    /**
     * 0.0.1
     */
    private String appVersion;

    private Boolean appOnline;

    /**
     * 下载地址
     */
    private String appDownloadUrl;

    /**
     * 版本描述
     */
    private String appDesc;

}
